home *** CD-ROM | disk | FTP | other *** search
/ Safarir 3 / SafTV-CD3.iso / pc / Bonus / Dessins Animés / static / jeux / teletub.swf / scripts / DefineButton2_182 / BUTTONCONDACTION on(press).as
Text File  |  2001-11-21  |  2KB  |  44 lines

  1. on(press){
  2.    tellTarget("../Actions_Weapons")
  3.    {
  4.       gotoAndStop("FireWeapon");
  5.       play();
  6.    }
  7.    if(eval("/:Weapon") == "3")
  8.    {
  9.       if("0" < eval("/:Rounds"))
  10.       {
  11.          Counter = "1";
  12.          while("10" >= Counter)
  13.          {
  14.             duplicateMovieClip("../CowSplat","Blood" add eval("/:Index"),eval("/:Index") + 16384);
  15.             setProperty("../Blood" add eval("/:Index"), _rotation, random("360"));
  16.             setProperty("../Blood" add eval("/:Index"), _X, getProperty("../Cursor", _X));
  17.             setProperty("../Blood" add eval("/:Index"), _Y, getProperty("../Cursor", _Y));
  18.             setProperty("../Blood" add eval("/:Index"), _xscale, "75");
  19.             setProperty("../Blood" add eval("/:Index"), _yscale, "75");
  20.             tellTarget("../Blood" add eval("/:Index"))
  21.             {
  22.                gotoAndPlay(2);
  23.             }
  24.             set("/:Index",eval("/:Index") + "1");
  25.             Counter += "1";
  26.          }
  27.          duplicateMovieClip("../Score+20","Score+20" add eval("/:Index"),eval("/:Index") + 16384);
  28.          setProperty("../Score+20" add eval("/:Index"), _X, getProperty("../Cursor", _X));
  29.          setProperty("../Score+20" add eval("/:Index"), _Y, getProperty("../Cursor", _Y) - "75");
  30.          tellTarget("../Score+20" add eval("/:Index"))
  31.          {
  32.             gotoAndPlay(2);
  33.          }
  34.          set("/:Index",eval("/:Index") + "1");
  35.          set("/:Score",eval("/:Score") + "20");
  36.          tellTarget("../Sounds_Announcer")
  37.          {
  38.             gotoAndPlay(2);
  39.          }
  40.          gotoAndPlay(39);
  41.       }
  42.    }
  43. }
  44.